<template>
  <div>
    <form action="http://www.itcast.cn" @click.prevent="fn">
      <input type="text" />

      <button>提交</button>
    </form>
  </div>
</template>
 
<script>
export default {
  data() {
    return {
      fn(e){
        e.preventDefault()
      }
    };
  },

  methods: {},
};
</script>

<style scoped>
</style>